public class Solution1 {
    public class Solution {
        public ListNode FindKthToTail (ListNode pHead, int k) {
            // write code here
            if(pHead == null) {
                return null;
            }
            ListNode cur = pHead;
            int count = 0;
            ListNode pser = pHead;
            while(pser.next != null) {
                while(k != 0) {
                    if(pser == null) {
                        return null;
                    }
                    pser = pser.next;
                    k--;
                    count = 1;
                }
                if(pser == null) {
                    return pHead;
                }
                cur = cur.next;
                pser = pser.next;
            }
            return cur.next;
        }
    }
}
